//
//  NetworkTools.swift
//  PersonnalDiary
//
//  Created by 徐宽阔 on 15/10/1.
//  Copyright © 2015年 XDKOO. All rights reserved.
//

import UIKit
import AFNetworking

class NetworkTools: AFHTTPSessionManager {
    private static let tools: NetworkTools = {
        let url = NSURL(string: "https://api.weibo.com/")!
        
        let manager = NetworkTools(baseURL: url)
        
        manager.responseSerializer.acceptableContentTypes = NSSet(objects: "application/json", "text/json", "text/javascript", "text/plain") as Set<NSObject>
        
        return manager
    }()
    
    class func shareNetworkTools() -> NetworkTools {
        return tools
    }
    
}
